Track visualization

All visualizations are implemented using the Plotly Graphing Library. All methods and functions return a Figure objects to enable additonal customization of the plot outside of the package e.g. using the update_layout method.

Elevations profiles

Multiple visualizations of the elevation profile of you tracks can be generated using the plot() method of the Tracks.

Profile with and without additional data

Using kind="profile" in plot() will generate a figure with the distance on the x-axis and the elevation on the y-axis. Internally this will call the plot_track_2d() function. See the api documentation for all options that can be passed.

Passing one of the boolean flags include_velocity, include_heartrate, include_cadence, or include_power will additonally plot the velocity, heartrate, cadence, or power on a secondary y-axis, respectively if available.

Profile with slopes

Using kind="profile-slope" in plot() will also generate a profile like before but additonally the slope between each point will be calcuated and viszalized in the plot by coloring the line and filling. Depending on the density of the points by using the reduce_pp_intervals argument. Internally this will call the plot_track_with_slope() function. See the api documentation for all options that can be passed.

Color scale and min/max slope can be configured using the slope_gradient_color, min_slope, and max_slope arguments as documented in plot_track_with_slope().

Map Visualizations

Multiple visualizations of the path of the track on a map can be generated using the plot() method of the Tracks. As default to Open Streetmap style is used for map. By passing map_style with a valid Plotly Mapboxstyle value this can be changed.

Line on map

Using kind="map-line" in plot() will generate a figure with the track path on a map. Internally this will call the plot_track_line_on_map() function. See the api documentation for all options that can be passed.

Individual segments lines with summary data on map

Using kind="map-segments" in plot() will generate a figure with the track path on a map. This plot can only be generated if the Track contains multiple segments. Otherwise an VisualizationSetupError will be raised. If two or more segments are present, the path will be split and colored into different segments and min/max/average of elevation, speed, heartrate, cadence, and power will be shown when hovering over the segment. Internally this will call the plot_segments_on_map() function. See the api documentation for all options that can be passed.

Line on map with additonal data

Using kind="map-line-enhanced" in plot() will generate a figure with the track path on a map. Additionally elevation, speed, heartrate, cadence, or power will be added via the color of the path. Set by passing the enrich_with_column argument. Internally this will call the plot_track_enriched_on_map() function. See the api documentation for all options that can be passed.

Unlike with the previous line plots, the individual track points are shown on the map and not the line connection consecutive points. For dense tracks this is no problem on normal zoom levels showing the whole track. But gaps may appear for sparse tracks as show below.

Use the inerpolate feature interpolate_points_in_segment() to increase the density with a following result: